package cn.shopifymall.studying.classloader;

/**
 * 三个默认类加载器
 *
 * @Author 孤风雪影
 * @Email gitee.com/efairy520
 * @Date 2025/1/15 15:41
 * @Version 1.0
 */
public class Demo01 {
    public static void main(String[] args) {
        ClassLoader cl1 = Demo01.class.getClassLoader();
        System.out.println("cl1 = " + cl1);
        ClassLoader parent = cl1.getParent();
        System.out.println("parent = " + parent);
        ClassLoader parentParent = parent.getParent();
        System.out.println("parentParent = " + parentParent);

        System.out.println("BootStrap ClassLoader加载目录：" + System.getProperty("sun.boot.class.path"));
        System.out.println("Extension ClassLoader加载目录：" + System.getProperty("java.ext.dirs"));
        System.out.println("App ClassLoader加载目录：" + System.getProperty("java.class.path"));
    }
}
